package com.youth.utils;

import java.util.UUID;

/**
 * @ClassName CodeUtil
 * @Description: TODO code生成类
 * @Author yjwu
 * @Date 2020/1/6 10:12
 **/
public class CodeUtil {
    /**
     * @MethodName: getCommodityCode
     * @Description: TODO 获取自动生成的code
     * @Param: * @param
     * @Return: {@link String}
     * @Author: yjwu
     * @Date: 2020/1/6 9:49
     **/
    public static String getUUIDCode() {
//        long nowTime=System.currentTimeMillis();
        UUID uuid = UUID.randomUUID();
        return uuid.toString().replaceAll("-", "");
//        UUID.nameUUIDFromBytes("AAA".getBytes());
    }
}
